<!DOCTYPE html>
<html lang="zh-CN">
  <head>
    <meta charset="UTF-8" />
    <meta http-equiv="X-UA-Compatible" content="IE=edge" />
    <meta name="viewport" content="width=device-width, initial-scale=1.0" />
    <title>登录页</title>
    <!--BootStrap CSS的引用文件-->
    <link rel="stylesheet" href="../static/bootstrap/css/bootstrap.min.css" />
    <link rel="stylesheet" href="../static/css/login.css" />
  </head>

  <body>
    <!-- 弹窗组件 -->
    <div th:replace="~{reuse/alertBox::alertBox}"></div>
    <div id="loginBox" class="container shadow" th:switch="${type}">
      <h1 class="text-center mt-5">医院管理集成系统</h1>
      <form
        th:case="activate"
        th:action="@{/admin/activate}"
        method="post"
        id="form"
        class="container my-5"
      >
        <div class="row text-danger-emphasis">
          <p class="text-center">
            输入您的身份证号激活该账号，请注意，一旦提交不可更改
          </p>
        </div>
        <div class="row justify-content-center mb-5 label">
          <label for="idcard" class="col-3 col-md-1 col-form-label"
            >身份证</label
          >
          <div class="col-9 col-md-7">
            <input
              type="text"
              class="form-control"
              placeholder="Please input your account"
              name="idcard"
            />
          </div>
        </div>
        <div class="row">
          <div class="col-3 col-md-2 mx-auto text-center">
            <button type="submit" class="btn btn-outline-primary">激活</button>
          </div>
        </div>
      </form>
      <form
        th:case="login"
        th:action="@{/admin/login}"
        method="post"
        id="form"
        class="container my-5"
      >
        <div class="row justify-content-center mb-5 label">
          <label for="account" class="col-2 col-md-1 col-form-label"
            >账户</label
          >
          <div class="col-10 col-md-7">
            <input
              type="text"
              class="form-control"
              placeholder="Please input your account"
              name="account"
            />
          </div>
        </div>
        <div class="row justify-content-center mb-5">
          <label for="password" class="col-2 col-md-1 col-form-label"
            >密码</label
          >
          <div class="col-10 col-md-7">
            <input
              type="password"
              class="form-control"
              placeholder="Please input your password"
              name="password"
            />
          </div>
        </div>
        <div class="row">
          <div class="col-3 col-md-2 mx-auto text-center">
            <button type="submit" class="btn btn-outline-primary">登录</button>
          </div>
        </div>
      </form>
    </div>

    <!--JS文件放body最下面会使浏览器先渲染完页面再加载JS提升流畅度-->
    <script src="../static/bootstrap/js/bootstrap.bundle.min.js"></script>
  </body>
</html>
